<template>
  <el-card class="box-card el-card-flex componentsTask cardHover">
    <div slot="header" class="clearfix">
      <span><i class="el-title-adorn"></i> 任务</span>
    </div>
    <el-tabs>
      <el-tab-pane label="进行中(11)" style="height: 275px;overflow: hidden;">
        <ul class="news-list">
          <li class="news-li">
            <dt class="news-title">
              <p>星宇友空间方案沟通</p>
              发起人：张驰 <span class="el-space"></span> 督办人：王鹏
            </dt>
            <dd class="news-date">2019-07-10</dd>
          </li>

          <li class="news-li">
            <dt class="news-title">
              <p>微服务技术中台演示环境数据维护</p>
              发起人：张驰 <span class="el-space"></span> 督办人：王鹏
            </dt>
            <dd class="news-date">2019-07-10</dd>
          </li>

          <li class="news-li">
            <dt class="news-title">
              <p>业务综合管理系统原型确认</p>
              发起人：张驰 <span class="el-space"></span> 督办人：王鹏
            </dt>
            <dd class="news-date">2019-07-10</dd>
          </li>

          <li class="news-li">
            <dt class="news-title">
              <p>“三重一大”数据上报</p>
              发起人：张驰 <span class="el-space"></span> 督办人：王鹏
            </dt>
            <dd class="news-date">2019-07-10</dd>
          </li>
          <li class="news-li">
            <dt class="news-title">
              <p>信息化考核需求分析与评估</p>
              发起人：张驰 <span class="el-space"></span> 督办人：王鹏
            </dt>
            <dd class="news-date">2019-07-10</dd>
          </li>
        </ul>
      </el-tab-pane>
      <el-tab-pane label="已延期" style="height: 300px;overflow: hidden;">
        <p style="text-align: center;">暂无数据...</p>
      </el-tab-pane>
      <el-tab-pane label="未开始" style="height: 300px;overflow: hidden;">
        <p style="text-align: center;">暂无数据...</p>
      </el-tab-pane>
    </el-tabs>
    <i @click="handDelProject" class="el-icon-close closeIcon"></i>
  </el-card>
</template>
<script>
import { MessageBox, Message, Tabs, TabPane } from 'element-ui'
export default {
  components: {
    'el-tabs': Tabs, // 标签页
    'el-tab-pane': TabPane, // 标签页列
  },
  data () {
    return {
      activeName: 'ongoing',
    }
  },
  methods: {
    // 显示编辑项目弹框
    editEvent () {
      this.$emit('editEvent')
    },
    // 删除任意一个布局里的项目
    handDelProject () {
      this.$emit('handDelProject')
    },
  }
}
</script>
<style lang="scss">
.componentsTask {
  padding: 0 10px;
  margin-bottom: 10px;
  position: relative;
  left: 0;
  top: 0;
  text-align: left;
  .closeIcon {
    position: absolute;
    right: 0;
    top: 0;
    padding: 3px;
    border-radius: 50%;
    background-color: #eeeeee;
    display: none;
  }
  .el-title-adorn {
    border-left: 3px solid #409EFF;
		display: inline-block;
		margin-right: 2px;
		height: 16px;
		vertical-align: middle;
		margin-top: -2px;
  }
  .el-card__header {
    border-bottom: none;
    padding: 5px 0 0 0;
  }
  .news-list {
    width: calc(100% + 25px);
    height: 100%;
    overflow: auto;
    cursor: pointer;
    .news-li {
      width: calc(100% - 25px);
      line-height: 25px;
      font-size: 12px;
      position: relative;
      padding: 5px;
      border-bottom: 1px solid #F4F6FC;
      box-sizing: border-box;
      display: table;
      text-align: left;
      .news-title {
        display: table-cell;
		  	vertical-align: middle;
        font-size: 12px;
        color: #000000;
         p {
          font-size: 15px;
          color: #000000;
        }
        .el-space {
          display: inline-block;
          width: 30px;
        }
      }
      .news-date {
        display: table-cell;
        text-align: right;
        vertical-align: middle;
        width: 100px;
        font-size: 12px;
		    color: #333333;
      }
      &:hover {
        color: #409EFF;
        text-decoration: underline;
        .news-date {
          color: #409EFF;
        }
      }
    }
  }
}
.cardHover {
  &:hover {
    background-color: rgba(254,227,78,.1);
    border: 1px dashed #fb9c68;
    .closeIcon {
      display: block;
    }
  }
}
</style>